import {
  get,
  post,
  //postForm,
  del,
} from "@/utils/http";
const packageName = `/back-api`;

/**
 * 巡检任务
 */

// 获取设备离线模板分组列表
export function getModelOfflineGroupList(params) {
  return get(
    `${packageName}/modelOfflineDevice/getModelOfflineGroupList`,
    params
  );
}

// 获取设备离线模板分组
export function getModelOfflineGroup(params) {
  return get(`${packageName}/modelOfflineDevice/getModelOfflineGroup`, params);
}

// 保存设备离线模板分组
export function saveModelOfflineGroup(params) {
  return post(
    `${packageName}/modelOfflineDevice/saveModelOfflineGroup`,
    params
  );
}
// 删除设备离线模板分组
export function delModelOfflineGroup(params) {
  return del(`${packageName}/modelOfflineDevice/delModelOfflineGroup`, params);
}
// 获取设备离线模板
export function getModelOfflineSettings(params) {
  return get(
    `${packageName}/modelOfflineSettings/getModelOfflineSettings`,
    params
  );
}
// 删除设备离线明细
export function delModelOfflineDetail(params) {
  return del(`${packageName}/modelOfflineDetail/delModelOfflineDetail`, params);
}
// 获取设备离线明细
export function getModelOfflineDetail(params) {
  return get(`${packageName}/modelOfflineDetail/getModelOfflineDetail`, params);
}
// 获取设备报警阈值设置列表
export function getModelOfflineDetailList(params) {
  return get(
    `${packageName}/modelOfflineDetail/getModelOfflineDetailList`,
    params
  );
}
// 保存设备离线明细
export function saveModelAlarmDetail(params) {
  return post(`${packageName}/modelOfflineDetail/saveModelAlarmDetail`, params);
}
// 删除离线模板设备
export function delModelOfflineDevice(params) {
  return del(`${packageName}/modelOfflineDevice/delModelOfflineDevice`, params);
}
// 获取离线模板设备
export function getModelOfflineDevice(params) {
  return get(`${packageName}/modelOfflineDevice/getModelOfflineDevice`, params);
}
// 获取离线模板设备列表
export function getModelOfflineDeviceList(params) {
  return get(
    `${packageName}/modelOfflineDevice/getModelOfflineDeviceList`,
    params
  );
}
// 保存离线模板设备
export function saveModelOfflineDevice(params) {
  return post(
    `${packageName}/modelOfflineDevice/saveModelOfflineDevice`,
    params
  );
}
// 删除设备离线模板
export function delModelOfflineSettings(params) {
  return del(
    `${packageName}/modelOfflineSettings/delModelOfflineSettings`,
    params
  );
}
// 获取设备离线模板列表
export function getModelOfflineSettingsList(params) {
  return get(
    `${packageName}/modelOfflineSettings/getModelOfflineSettingsList`,
    params
  );
}
// 获取离线模板明细(模板id)
export function getModelOfflineSettingsDetail(params) {
  return get(
    `${packageName}/modelOfflineSettings/getModelOfflineSettingsDetail`,
    params
  );
}
// 保存设备离线模板
export function saveModelOfflineSettings(params) {
  return post(
    `${packageName}/modelOfflineSettings/saveModelOfflineSettings`,
    params
  );
}
// 保存离线模板明细
export function saveModelOfflineSettingsDetail(params) {
    return post(
      `${packageName}/modelOfflineSettings/saveModelOfflineSettingsDetail`,
      params
    );
  }
  //获取全部设备离线模板列表(公司id)
  export function getModelOfflineSettingss(params) {
    return get(
      `${packageName}/modelOfflineSettings/getModelOfflineSettingss`,
      params
    );
  }